load

abstract suspend fun load(scene: String, overrideEditorConfig: Boolean = false, waitForResources: Boolean = false): DesignBlock

Load the contents of a scene file.

Return

the handle to the loaded scene.

Parameters

scene

The scene file contents, a base64 string.

overrideEditorConfig

Whether to override editor configuration with settings and data from the scene file. Defaults to false.

waitForResources

Whether to wait for all resources to finish loading before returning. Defaults to false.


abstract suspend fun load(sceneUri: Uri, overrideEditorConfig: Boolean = false, waitForResources: Boolean = false): DesignBlock

Load a scene from the resource of a scene or archive file. The file will be fetched asynchronously by the engine and loaded as an archive or as a scene file depending on its content. This loads .imgly files as well as the legacy .scene and .zip formats.

Return

the handle to the loaded scene.

Parameters

sceneUri

the resource to load: a scene file or an archive.

overrideEditorConfig

Whether to override editor configuration with settings and data from the scene file. Defaults to false.

waitForResources

Whether to wait for all resources to finish loading before returning. Defaults to false.